package com.lpfy.dtxc;

import android.app.Service;
import android.content.ComponentName;
import android.content.Intent;
import android.os.IBinder;
import android.util.Log;

import androidx.annotation.Nullable;

/**
 * @author: hanGuangHui
 * @data: 2024/3/13
 * @description:
 */
public class MyService extends Service {

    @Override
    public int onStartCommand(Intent intent, int flags, int startId) {
        // 在此处处理应用退出后的逻辑
        Log.e("--------onStartCommand",intent.getAction());
        ComponentName componentName = new ComponentName("com.lpfy.dtxc", "com.lpfy.dtxc.HomeActivity");
        Intent intent1 = new Intent();
        intent1.setComponent(componentName);
        startActivity(intent1);
        return START_STICKY;
    }

    @Nullable
    @Override
    public IBinder onBind(Intent intent) {
        return null;
    }
}
